Specialized network fileserver

ABSTRACT

A method and apparatus of a portable storage device that provides a specialized network fileserver is described. In an exemplary method, the portable storage device retrieves a list of applications on the portable storage device, where each of the applications has a private filesystem. For each of the applications, the portable storage device determines if that application will share the corresponding private filesystem and adds that private filesystem to a shared filesystem of the portable storage device is that is shareable. The portable storage device further advertises the shared filesystem to a host that is coupled to the portable storage device.

RELATED APPLICATIONS

Applicant claims the benefit of priority of prior, provisionalapplication Ser. No. 61/295,660, filed Jan. 15, 2010, the entirety ofwhich is incorporated by reference.

FIELD OF THE INVENTION

This invention relates generally to coupling devices and moreparticularly to creating a storage interface between a portable storagedevice and host.

BACKGROUND OF THE INVENTION

A portable storage device, such as a portable music player, smartphone,etc., can be connected with a host, such as a personal computer orlaptop over a universal serial bus (USB) link. When these two devicesare connected, information between the host and the portable storagedevice can be communicated using a vendor-specific packet-orientedmultiplexing protocol. For example, multimedia files, applications,contact information, etc. can be transferred between the two devices.

In one scenario, the host and portable storage device can multiplex USBand transmission control protocol (TCP)/Internet protocol (IP)communications over the USB link coupling the two devices. In thisscenario, a network interface is configured on the USB link to enableTCP/IP-type communication over the USB link. This network interface canbe used to communicate TCP/IP packets on this link. By enabling theTCP/IP-type communication, a disruption in the link can be gracefullyhandled. For example, an application on each of the host and theportable storage can establish a TCP session between these twoapplications, which is used to communicate data between the twoapplications. The TCP stack notifies the applications if there is adisconnection in the session, presumably caused by a disconnection inthe underlying USB link. The host and portable device applications canuse the notifications to gracefully recover from the communicationdisruption.

SUMMARY OF THE DESCRIPTION

A method and apparatus of a portable storage device that provides aspecialized network fileserver is described. In an exemplary method, theportable storage device retrieves a list of applications on the portablestorage device, where each of the applications has a private filesystem.For each of the applications, the portable storage device determines ifthat application will share the corresponding private filesystem andadds that private filesystem to a shared filesystem of the portablestorage device is that is shareable. The portable storage device furtheradvertises the shared filesystem to a host that is coupled to theportable storage device.

In one embodiment, a portable storage device is configured to enable atethering interface and a portable storage interface on a linkinterface. In response to detecting a host coupled to that link, themethod configures the tethering interface to allow the host access to anetwork and configures the portable storage interface to share filesbetween the host and the portable storage device. The method furthercommunicates data between the host and the network with the tetheringinterface and shares files stored on the portable storage device withthe host through the portable storage interface.

In another embodiment, the portable storage device retrieves a list of aplurality of applications resident on the portable storage device, whereeach of the plurality of applications has a private filesystem of files.For the each of the plurality of applications, the portable storagedevice determines if that application will share its private filesystemto a shared filesystem of the portable storage device. The portablestorage device further adds to the shared filesystem a link to theprivate filesystem of that application if the private filesystem isshareable. In addition, the portable storage device advertises theshared filesystem of the portable storage device to a host that iscoupled to the portable storage device.

In a further embodiment, the portable storage device receives a requestto access the shared filesystem from the host, where the sharedfilesystem includes files that correspond to a plurality of applicationson the portable storage device and a security policy that disallows oneof the plurality of applications from accessing a file in the sharedfilesystem that corresponds to another one or many of the plurality ofapplications. In addition, the portable storage device fulfills thatrequest.

In another embodiment, the host transmits a request to access the sharedfilesystem from the host, where the shared filesystem includes filesthat correspond to a plurality of applications on the portable storagedevice and a security policy that disallows one of the plurality ofapplications from accessing a file in the shared filesystem thatcorresponds to another one or many of the plurality of applications. Inaddition, the host receives an indication of the result of the request.

In one embodiment, the host receives an advertisement from a portablestorage service that a shared filesystem is available for use. The hostdetermines if the portable storage device corresponding to theadvertised portable storage services is known to the host. If theportable storage device is known to the host, the host receives aninternet protocol (IP) address to configure a portable storage interfaceon the host. Once this interface is configured, the host transmits arequest to the portable storage service to mount a shared filesystem ofthe portable storage service for the host. The host receives anotification that the shared filesystem is mounted and applicationsresident on the host can access the files in the shared filesystem.

BRIEF DESCRIPTION OF THE DRAWINGS

The present invention is illustrated by way of example and notlimitation in the figures of the accompanying drawings in which likereferences indicate similar elements.

FIG. 1 is a block diagram of one embodiment of a portable storage devicethat couples to a host and can provide a tether and a portable storageservice for the host.

FIG. 2 is a block diagram of one embodiment of a connection between theportable storage device and the host.

FIG. 3 is a block diagram of one embodiment of system components thatutilize the portable storage device-host connection.

FIG. 4 is a block diagram of one embodiment of a portable storageservice on the portable storage device.

FIG. 5 is a block diagram of one embodiment of a shared filesystem inthe portable storage device.

FIG. 6 is a flow diagram of one embodiment of a process to create a dualEthernet channel connection between the portable storage device and thehost.

FIG. 7 is a flow diagram of one embodiment of a process to build theshared filesystem on the portable storage device.

FIG. 8 is a flow diagram of one embodiment of a process to configure thehost so as to be able to access the shared filesystem on the portablestorage device.

FIG. 9 is a flow diagram of one embodiment of a process to respond toaccess request for the shared filesystem on the portable storage device.

FIG. 10 is a flow diagram of one embodiment of a process to access theshared filesystem of the portable storage device.

FIG. 11 is a block diagram of a portable storage configuration modulethat creates the dual Ethernet channel connection between the portablestorage device and the host.

FIG. 12 is a block diagram of a launch portable service module thatcreates the shareable filesystem on the portable storage device.

FIG. 13 is a block diagram of a host configuration module thatconfigures the host to be able to access the shared filesystem on theportable storage device.

FIG. 14A is a block diagram of a file server module that handlesaccesses to the shared filesystem on the portable storage device.

FIG. 14B is a block diagram of a file server module that makes accessesrequests to the shared filesystem on the portable storage device.

FIG. 15 illustrates one example of a typical computer system which maybe used in conjunction with the embodiments described herein.

FIG. 16 shows an example of a data processing system which may be usedwith one embodiment of the present invention.

DETAILED DESCRIPTION

A method and apparatus of a portable storage device that provides atethering and a portable storage service to a host is described. In thefollowing description, numerous specific details are set forth toprovide thorough explanation of embodiments of the present invention. Itwill be apparent, however, to one skilled in the art, that embodimentsof the present invention may be practiced without these specificdetails. In other instances, well-known components, structures, andtechniques have not been shown in detail in order not to obscure theunderstanding of this description.

Reference in the specification to “one embodiment” or “an embodiment”means that a particular feature, structure, or characteristic describedin connection with the embodiment can be included in at least oneembodiment of the invention. The appearances of the phrase “in oneembodiment” in various places in the specification do not necessarilyall refer to the same embodiment.

The processes depicted in the figures that follow, are performed byprocessing logic that comprises hardware (e.g., circuitry, dedicatedlogic, etc.), software (such as is run on a general-purpose computersystem or a dedicated machine), or a combination of both. Although theprocesses are described below in terms of some sequential operations, itshould be appreciated that some of the operations described may beperformed in different order. Moreover, some operations may be performedin parallel rather than sequentially.

The term “host” and the term “portable storage device” are intended torefer generally to data processing systems rather than specifically to aparticular form factor for the host versus a form factor for the device.

A method and apparatus of a portable storage device that provides atethering and a portable storage service to a host is described. In anexemplary method, the portable storage device configures a tethering anda portable storage service interface for the host. The portable storagedevice provides the tethering service to a network for the host throughthe tethering interface. In addition, the portable storage device sharesfiles stored on the portable storage device through the portable storageinterface.

FIG. 1 is a block diagram of one embodiment of a portable storage device104 that couples to a host 102 and can provide tethering for the host102. As is known in the art, tethering is the use of a mobile device(e.g., the portable storage device) to supply network access for anotherdevice (e.g., the host). In FIG. 1, the portable storage device 104couples to the host 102 via a host-device link 106. A host 102 is one ofa personal computer, smartphone, cellular phone, music player, laptop,notebook, tablet, personal digital assistant, netbook, palmtop computer,server, etc. Portable storage device 104 is a mobile device capable ofstoring data, such as smartphone, mobile player, cellularphone, tablet,laptop, notebook, etc. While in one embodiment, the host-device link 106is a universal serial bus (USB), in alternate embodiments, thehost-device link 106 is another type of link capable of communicatingdata between the host 102 and the portable storage device 104 (Firewire,Ethernet, wireless, serial connection, Bluetooth®, etc.). For example,and in one embodiment, the host 102 is a laptop or other type ofpersonal computer and the portable storage device 104 is a smartphone ortablet that is coupled to the host 102 using a USB link.

In one embodiment, the portable storage device provides two services tothe host, a tethering service 114 and a portable storage service 112over the host-device link 106. The tethering service 114 providesnetwork access to network 108 for the host 102 via the portable storagedevice 104. The portable storage service 112 provides access for thehost 102 to files stored on the portable storage device 104.

In one embodiment, the portable storage device 104 is coupled to anetwork 108 via device-network link 110. In one embodiment, network 108is a wide-area-network that provides network services to the portablestorage device 104 and/or host 102. For example, and in one embodiment,network 108 is the Internet, a cellular network (3G, etc.), or othertype of wide area network known in the art. Device-network link 110 istype of link that corresponds to the type of network 108. For example,and in one embodiment, device-network link 110 is a 3G wireless link,Wi-fi wireless link, WIMAX link, etc. In one embodiment, by coupling theportable storage device 104 to the network 108, the portable storagedevice 104 can tether the host 102 via the tethering service 114 to thenetwork 108 in order to provide access to network services supported bynetwork 108. In this embodiment, the host-device link 106 is utilized tocommunicate data between the host 102 and network 108. Setting up thehost-device link 110 to tether the host 102 to the network 108 isfurther discussed in FIGS. 2, 3, and 6 below.

In another embodiment, portable storage device 104 includes file storagethat is accessible by host 102 via the host-device link 106 storage andthe portable storage service 112. In this embodiment, a fileserver isresident on the portable storage device that can allow access to afilesystem on the portable storage device 104.

As described above, the host-device link 106 can support access by thehost 102 to the filesystem on the portable storage device 104 and accessfor host 102 to the network 108 via the portable storage device 104. Inone embodiment, two communication channels are created on thehost-device link 106 to support these functions. FIG. 2 is a blockdiagram of one embodiment of a connection 216 between the portablestorage device 222 and the host 220 that supports tethering andfilesystem access. In FIG. 2, host 220 comprises listener interface 202,tethering interface 224, Ethernet over USB interface 204, and USBinterface 206. Portable storage device 222 comprises portable storageinterface 212, tethering interface 214, Ethernet over USB interface 210,and USB interface 208. In this embodiment, the host 220 and the portablestorage device 222 are connected by a USB link that includes these twoEthernet channels 218A-B.

In one embodiment, one of the Ethernet channels is used for thetethering function and the other is used to provide fileserverfunctionality. For example and in one embodiment, Ethernet channel 218Ais used to provide the tethering service to the host 220 and Ethernetchannel 218B is used to provide fileserver access for the host. In thisembodiment, Ethernet channel 218A couples the tethering interface 224 onthe host 220 and tethering interface 214 on the portable storage device222. In addition, Ethernet channel 218B couples file browser listenerinterface 202 on the host 220 and portable storage interface 212 on theportable storage device 222.

In this embodiment, internet protocol (IP) addresses are assigned toeach Ethernet interface in order to allow data to be communicated overthe each Ethernet channel. For example and in one embodiment, an IPaddress is assigned to interfaces 202 and 224. In one embodiment, othernetwork functions interface 224 is assigned an IP address thatcorresponds to Ethernet channel 218A and allows data communicated overEthernet channel 218A to reach network that is tethered to portablestorage device 222. For example and in one embodiment, tetheringinterface 224 is assigned a public IP address or a private address knownto network 108. In another embodiment, file browser listener interface202 is assigned an IP address that corresponds to Ethernet channel 218Band allows host 220 to access a shared filesystem on portable storagedevice 222. For example and in one embodiment, file browser listenerinterface 202 is assigned a private IP address that is used for theshared filesystem, but does not allow the host 220 to access othernetwork services (e.g., tethering) across this interface. In oneembodiment, the Ethernet interfaces for each of the two Ethernetchannels are assigned IP addresses that are from two different networks.For example and in one embodiment, the tethering network has addressesthat allow the host 102 to access the network 108. The file sharingnetwork has private addresses that are used for the file sharing betweenthe host 102 and portable storage device 104.

FIG. 3 is a block diagram of one embodiment of system components thatutilize the portable storage device-host connection. In FIG. 3, the host314 is coupled to a portable storage device 316 with a USB link 338. Inone embodiment, the host 314 is host 102 of FIG. 1 that couples with theportable storage device 104 to access network 108 and the portablestorage service 112 of the portable storage device 104. The host 314includes a USB interface 308, Ethernet input/output interface 344, andtwo Ethernet interfaces 306A-B in kernel space 312 and a set ofcomponents in user space 310. In one embodiment, Ethernet input/output344 is an Ethernet over USB interface, such as Ethernet over USBinterface 204 as described in FIG. 2 above. The individual Ethernetinterfaces 306A-B are defined on top of Ethernet input/output 344. Inone embodiment, this set of components includes a tether component 302,listener 304, and host file browser 340. The tether component 302 usesEthernet interface eth1 306A to tether with the portable storage device316 as described above in FIGS. 1 and 2. Listener 304 listens forfilesystem advertisements. If the listener 304 receives a filesystemadvertisement, listener 306 mounts the filesystem as a shared volume onhost 314. For example and in one embodiment, listener 304 listens for anew filesystem that is mounted and shared on the portable storage device316. File browser 340 makes requests to the shared filesystem on theportable storage device 316. In one embodiment, user space is a memoryand operating mode where user programs and applications run, e.g. a wordprocessing application. Kernel space is where the operating systemitself and device drivers run, which has full privileges to access thehardware.

The portable storage device 316 includes a USB interface 318, theEthernet input/output 320, and two Ethernet interfaces 322A-B in kernelspace 334 and a set of components in user space 336. In one embodiment,Ethernet input/output 320 is an Ethernet over USB interface, such asEthernet over USB interface 210 as described in FIG. 2 above. Theindividual Ethernet interfaces 322A-B are defined on top of Ethernetinput/output 320. In one embodiment, the portable storage device 316 isa device that provides tethering and portable storage services to thehost 314. In one embodiment, the set of components on the portablestorage device 316 include tether 326, network file server 328, a set ofapplications 332, and a configuration process, configd, 330. Tethercomponent 326 uses the Ethernet eth0 interface 322A to provide tetheringservices to the host 314. In one embodiment, network file server 332builds and exports the shared filesystem for the portable storage device316 that is used by the host 314. Network file server 328 builds thefilesystem by determining which of the applications will share the filesin the private filesystem of those applications 332 and adds links toeach of those shared private filesystems. In this embodiment, eachapplication resident on the portable storage device 316 has its ownprivate filesystem that is not shared with other applications on theportable storage device 316. Further discussion of how the network fileserver 328 builds and exports the shared filesystem is in FIGS. 4 and 5below.

The portable storage device 316 further includes a set of USBconfiguration files 340 and an Ethernet configuration file 324. In oneembodiment, the different USB configuration files are used for differentconfigurations of the USB link. For example and in one embodiment, thereis a configuration for the USB having two Ethernet channel on the USBlink (e.g., tethering and file serving Ethernet channel), one Ethernetchannel on the USB link (e.g. tethering or file serving Ethernetchannel), and no Ethernet channels (e.g., USB link configured to haveUSB capability as known in the art). In one embodiment, the USBconfiguration is chosen based on the model of the portable storagedevice (e.g. media player, smartphone, etc), and the services running onthe device. For example and in one embodiment, when tethering is turnedon through preferences on the device, then the portable device operatingsystem will select the USB configuration that includes the tetheringinterface. In one embodiment, the Ethernet configuration file is used toattach a property to each of the Ethernet interfaces 322A and 332B toindicate which one of the interfaces 3222A-B is the tethering interfaceand which is the portable storage interface. This property is thenexamined by the configd 330 so that it can attach the portable storageuser space daemon to the correct Ethernet interface.

In one embodiment, the user space configuration daemon configd 330configures the Network file server based on the USB configuration filesused to configure the USB link. In one embodiment, configd 330configures and starts the Network file server 328 upon coupling of theportable storage device 316 to the host 314. In an alternate embodiment,configd 330 configures and starts the Network file server upon theportable storage device 316 booting up. In a further embodiment, configd330 configures and starts the Network file server if the USB link isconfigured (or to be configured) with an Ethernet channel that is usedfor file serving.

As described above, the portable storage device can include a portablestorage service resident on the portable storage device. In oneembodiment, the portable storage service is a network file server andthe shared filesystem used by the portable storage service isconstructed from the private file systems of applications resident onthe portable storage device. FIG. 4 is a block diagram of one embodimentof a portable storage service 400 on the portable storage device. InFIG. 4, the portable storage service 400 includes network file server402 and a shared filesystem that is coupled to applications 404A-N,application private storage 406A-N, application sandboxes 410A-N, and ahost application 412 that can access the shared filesystem 408. Anapplication 404A-N can be any type of application known in the art thatcan be run on a computer or portable storage device (e.g., e-mail, webbrowsing, multimedia use/manipulation, note taking, work processing,spreadsheet, etc.). In one embodiment, an application private storage406A-N includes files that are used by the application, such asuser-created documents, library files, object files, executables,configuration files, cached data, database files, images displayed bythe application etc. In one embodiment, each application 404A-N andcorresponding private storage 406A-N is enclosed within an applicationsandbox 410A-N that prevents an application from accessing files createdby another application. For example and in one embodiment, application404A access files in application private storage 406A, but cannot accessfiles in another application private storage 406B-N.

In one embodiment, the network file server 402 constructs the sharedfilesystem 408 from the applications 404A-N and the correspondingapplication private storage 406A-N. In one embodiment, for eachapplication 404A-N that allows access to the corresponding privatestorage 406A-N, the network file server 402 adds a link to the sharedfilesystem 408 for that accessible private storage. For example and inone embodiment, the network file server 402 links to the applicationprivate storage 406A-N for each application 404A-N that participates inthe portable storage service 400. This added link can allow access to apart or all of the application's private storage 406A-N. In oneembodiment, the added link allows access to user-created files in theapplication private storage. For example and in one embodiment, anote-taking application on the portable storage device creates andstores user created notes in files in the private storage for thatnote-taking application. If the note-taking application is configured toshare the user created notes, network file server 402 links the sharedfilesystem 408 to a directory in the note taking application privatestorage that stores the user created notes. In this embodiment, the usercreated notes can be accessed by the host application 412.

Once the network file server 402 constructs the shared filesystem 408,the network file server 402 advertises the existence of the sharedfilesystem 408 to the host. In one embodiment, portable storage serviceuses the Bonjour service discovery protocol to advertise the portablestorage service 400 to the host. In this embodiment, the host receivesthe advertisements and sends a request to the network file server 402 tomount the shared filesystem 408.

As described above, the shared filesystem of the portable storageservice is constructed by linking to the private storage of applicationsthat participate in the portable storage service. FIG. 5 is a blockdiagram of one embodiment of a shared filesystem 502 on the portablestorage device. In FIG. 5, the shared filesystem 502 links toapplication private filesystems 506A-N. Each of the links 504A-N is usedto construct the shared filesystem 502. In one embodiment, the networkfile server 502 advertises this shared filesystem 502 to the hostcoupled to the client.

In one embodiment, the network file server 502 links to part of anapplication private filesystem 506A. In this embodiment, the applicationprivate filesystem 506A includes shared files 510A, library files 510B,configuration files 510C, and other non-shared files 510D. In oneembodiment, the shared files 510A are user-created files that have beencreated using the corresponding application on the client.Alternatively, these user-created files were created on another device(e.g., the host or some other device, etc.) and downloaded via theshared filesystem 502 to the shared files 510A portion of theapplication private filesystem 506A. In one embodiment, the shared files510A is a directory in the application private filesystem 506A. Bylinking to the shared files 510A, a host can access the files in theshared files 510A via the shared volume 508.

In one embodiment, an application 514 on the host can access files onthe client via the shared filesystem 502. In this embodiment, theapplication 514 can perform any of the operations on these files thatare known in the art (e.g., reading from, writing to, listing filecharacteristics, creating, deleting, etc.). In another embodiment, someof the file operations are restricted as known in the art (e.g., able toread the file, but not write to the file, etc.). In another embodiment,a host application of a different type can perform file operations onone of the shared file associated with a different type of application.For example and in one embodiment, a word processing application on thehost could access files through the shared filesystem 502 that areassociated with a note-taking application resident on the client. Inaddition, in one embodiment, a word processing application resident onthe client that is the same as the one on the host would not be able toaccess those files because of the security sandbox that envelops each ofthe applications resident on the client. In another embodiment, the onetype of application on the host can access application files 506A-N onthe client associated with the same type of client. For example and inone embodiment, a note-taking application on the host could access filesthrough the shared filesystem 502 that are associated with a note-takingapplication resident on the client. In one embodiment, the same type ofapplication can mean two applications the same type of functionality onthe host and client, but these programs are specialized for one or bothdevices. For example and in one embodiment, a photo processingapplication on the host can access files of a specialized version ofthat photo processing program that is resident on the client.

FIG. 6 is a flow diagram of one embodiment of a process 600 to create adual Ethernet channel connection between the portable storage device andthe host. In FIG. 6, process 600 enables portable storage on theportable storage device at block 602. In one embodiment, a configurationvariable is set to “true.” At block 604, process 600 publishes aportable storage key that signals to the configuration daemon that thestorage server is enabled. In one embodiment, when the portable storagedevice boots up, process 600 inspects that configuration variable andpublishes the key.

Process 600 configures the portable storage Ethernet interface at block606. In one embodiment, process 600 changes the portable storagedevice's USB configuration to include an Ethernet profile. In thisembodiment, including the Ethernet profile in the USB configurationallows the USB interface to be configured with Ethernet running on topof the USB link as described with reference to FIGS. 1 and 2 above. Inone embodiment, the Ethernet interface is not quite up and running, butwill come up when until the host couples with the portable storagedevice.

At block 608, process 600 detects that the portable storage device 608is coupled to the host. In one embodiment, process 600 detects thecoupling by detecting a physical USB connection being made to the USBinterface of the portable storage device. In another embodiment, thehost detects that the device has joined the local area network byreceiving network packets over WiFi or Ethernet interfaces

Process 600 determines if tethering is enabled at block 610. In oneembodiment, process 600 determines if tethering is enabled by querying aconfiguration parameter or key for tethering. If tethering is notenabled, execution proceeds to block 614. If tethering is enabled,process 600 configures the Ethernet interface for tethering to the hoston the USB link at block 612. In one embodiment, process 600 brings thisinterface up and assigns an IP address suitable to support the tetheringfunctionality. In one embodiment, process 600 receives an IP address andother configuration information (nameserver address, gateway, etc.) froma network that is being used for the tethering and assigns this IPaddress to the tethering Ethernet interface. Execution proceeds to block614.

At block 614, process 600 configures an Ethernet interface for theportable storage service. In one embodiment, assigns a private IPaddress that is to be used on a private network between the portablestorage device and the host for file sharing. For example and in oneembodiment, process 600 assigns an IP address of 192.168.20.1.

Process 600 launches the portable storage server at block 616. In oneembodiment, process 600 creates a file that signals the network fileserver to start. When this file exists, the portable storage Ethernetinterface is up and available to use. In addition, process 600 launchesthe network file server and turns on the Dynamic Host ConfigurationProtocol (DHCP) server on the portable storage device. In oneembodiment, this DHCP server is used to assign a private IP address tothe host Ethernet interface used for the file serving as described inFIG. 2 above. In addition, process 600 advertises the portable storageservice. In one embodiment, the portable storage service is the sharedfilesystem served by the network file server as described above withreference to FIG. 4 above. In one embodiment, process 600 advertises theportable storage service with a service discovery protocol known in theart (e.g., Bonjour, Zeroconf, universal plug and play (UPnP), etc.).

Furthermore, process 600 builds the sharable filesystem used by thenetwork file server at block 616. In one embodiment, for eachapplication resident on the portable storage device that wants to opt-into the portable storage service, the network file server creates a linkto the shared files for that application. Building of the sharedfilesystem is further described in FIG. 7 below.

At block 618, process 600 mounts the shared filesystem so that the hostcan in turn mount the shared filesystem on the host. In one embodiment,an SMB client on the host mounts one volume from a shared volume on eachportable storage device coupled to the host. In one embodiment, upon thehost coupling with the portable storage device, process 600 communicatesthe data associated with the tethering and portable storage service overthe USB link and corresponding Ethernet channels with the host at block620.

As described above, the process 600 builds a shared filesystem for theportable storage service. FIG. 7 is a flow diagram of one embodiment ofa process 700 to build the shared filesystem on the portable storagedevice. In one embodiment, process 700 is executed by process 600 atblock 616 in FIG. 6 above. In FIG. 7, process 700 retrieves the list ofapplications resident on the portable storage device. In one embodiment,the server on the portable storage device gets the list from anapplication installation service built into the portable storage deviceoperating system. It receives information about each application,including the flag that says whether the application participates inportable storage service. Process 700 further executes a processing loop(blocks 704-712) to generate a set of links to the applications sharedfiles. At block 706, process 700 determines if an application willshares its files. In one embodiment, an application that shares itsfiles adds a key to an application configuration file to indicate theapplication file sharing is turned on. In this embodiment, process 700reads this key that indicates this application wishes to shares thatfiles. If the key is present, execution proceeds to block 708. If thiskey is not present, the application does not share its files andexecution proceeds to block 712.

At block 708, process 700 generates a link to the directory of theshared files of the application. In one embodiment, the shared filesdirectory is a directory created when the application sets the keyindicating that its files are shareable. Process 700 adds theapplication storage link to the shared filesystem at block 710. Theprocessing loop ends at block 712.

With the portable storage service started and the storage Ethernetinterface available, the host will configure itself to take advantage ofthe portable storage service. FIG. 8 is flow diagrams of one embodimentof a process 800 to configure the host so as to be able to access theshared filesystem on the portable storage device. In one embodiment, onthe host side, a listener executes process 800. At block 802, process800 starts a listening process. In one embodiment, the listening processlistens for the service discovery protocol advertisements of theportable storage service.

Process 800 receives an advertisement of the portable storage service atblock 804. In one embodiment, the advertisement is an advertisementusing a service discovery protocol known in the art (Bonjour, Zeroconf,etc.). In another embodiment, the advertisement includes an identifierof the portable storage device. For example and in one embodiment, thereceived advertisement identifier is the serial number of the portablestorage device.

At block 806, process 800 determines if the portable storage device isknown to process 800. In one embodiment, process compares the portablestorage device identifier received in the advertisement with a list ofknown devices. For example and in one embodiment, process 800 determinesif the portable storage device has been paired with the host. If theportable storage device is not known to process 800, process 800 signalsa failure at block 818 For example an in one embodiment, if the portablestorage device is not paired with the host, the network interface on thedevice will not be activated by configd, and no connection will bepossible from the host.

If the portable storage device is known to process 800, process 800waits to receive an IP address that can be used to configure theportable storage Ethernet interface at block 808. If process 800 doesnot receive an IP address, process 800 signals a failure at block 818.However, if process 800 receives the IP address, process 800 configuresthe portable storage Ethernet interface at block 810. In one embodiment,process 800 applies the received IP address along with otherconfiguration information for that interface as described above in FIG.3 (nameserver address, gateway, etc.).

At block 812, process 800 transmits a mount request to the portablestorage service to mount the shared filesystem on the host. In oneembodiment, process 800 sends a request using the user name “guest” andno password. In this embodiment, no username and password is usedbecause portable storage device is known to the host. Process 800receives a notification that the shared filesystem is mounted at block814. At block 816, process 800 displays the shared filesystem in a filebrowser application running on the host. In one embodiment, the sharedfilesystem is also available to other applications running on the host.

FIG. 9 is flow diagrams of one embodiment of a process 900 to respond toan access request for the shared filesystem on the portable storagedevice. In one embodiment, process 900 receives requests from anapplication on the host. In this embodiment, process 900 does notreceive filesystem request from applications on the portable storagedevice because the portable storage service is made available to thehost and not to applications running on the portable storage device. InFIG. 9, at block 902, process 900 receives a filesystem access request.In one embodiment, the filesystem request is a SMB request to access thesharable filesystem. As is known in the art, a SMB request can be usedto open, close, read, write, lock, unlock, etc. files as well asretrieve or set file characteristics. At block 904, process 900 fulfillsthe filesystem request. In one embodiment, process 900 performs a fileoperation (open, close, read, write, lock, unlock, list, etc.) andreturns a return code indicating success/failure to the host and otherrelevant data for the request (data read, pointer, lock, etc.).

FIG. 10 is a flow diagram of one embodiment of a process 1000 to accessthe shared filesystem of the portable storage device. In FIG. 10, atblock 1002, process 1000 transmits a filesystem access request to theportable storage service. In one embodiment, the filesystem request is aSMB request to access the sharable filesystem. As is known in the art, aSMB request can be used to open, close, read, write, lock, unlock, etc.files as well as retrieve or set file characteristics. At block 1004,process 1000 receives the result of the filesystem access. In oneembodiment, process 1000 receives a return code indicatingsuccess/failure of the operation and other relevant data for the request(data read, pointer, lock, etc.).

FIG. 11 is a block diagram of a portable storage configuration module1000 that creates the dual Ethernet channel connection between theportable storage device and the host. In one embodiment, the portablestorage configuration module 1000 is the configd 330 of FIG. 3 above. InFIG. 11, portable storage configuration module 1000 comprises an enableportable storage modules 1102, publish portable storage key 1104,configure Ethernet interface module 1106, host link detection module1108, tethering module 1110, portable storage Ethernet module 1112,launch portable storage service module 1114, and communication module1116. Enable portable storage module 1102 enables the portable storageas described in FIG. 6, block 602. Publish portable storage key 1104publishes the portable storage key that enables portable storage asdescribed in FIG. 6, block 604. Configure Ethernet interface module 1106configures the portable storage Ethernet interface as described in FIG.6, block 606. Host link detection module 1108 detects that the portablestorage device is coupled to a host as described in FIG. 6, block 608.Tethering module 1110 configures the tethering Ethernet interface asdescribed in FIG. 6, block 612. Portable storage Ethernet module 1112configures the Ethernet interface for portable storage as described inFIG. 6, block 614. Launch portable storage service module 1114 launchesthe portable storage service as described in FIG. 6, block 616.Communication module 1116 communicates data as described in FIG. 6,block 620.

FIG. 12 is a block diagram of launch portable storage module 1114 thatlaunches the portable storage service on the portable storage device. InFIG. 12, launch portable storage module 1114 includes application listmodule 1202, application storage module 1204, application link module1206, and shared filesystem 1208. Application list module 1202 retrievesthe list of applications resident on the portable storage device asdescribed in FIG. 7, block 702. Application storage module 1204determines if the application private storage is shareable as describedin FIG. 7, block 706. Application link module 1206 generates anapplication storage link as described in FIG. 7, block 708. Sharedfilesystem 1208 adds the application storage link to the sharedfilesystem as described in FIG. 7, block 710.

FIG. 13 is a block diagram of host configuration module 1300 thatconfigures the host to be able to access the shared filesystem on theportable storage device. In one embodiment, the host configurationmodule is the host configuration component 342 as described in FIG. 3above. In FIG. 13, host configuration module 1300 includes startlistener module 1302, receive advertisement module 1304, check portablestorage device module 1306, receive Ethernet configuration module 1308,configuration Ethernet interface module 1308, filesystem mount requestmodule 1312, receive filesystem mount module 1314, display mountedfilesystem module 1316, and signal failure module 1318. Start listenermodule 1302 starts the listener as described in FIG. 8, block 802.Receive advertisement module 1304 receive the portable storage serviceadvertisement as described in FIG. 8, block 804. Check portable storagedevice module 1306 checks the portable storage device identifier asdescribed in FIG. 8, block 806. Receive Ethernet configuration module1308 receives the Ethernet configuration for the portable storageinterface as described in FIG. 8, block 808. Configuration Ethernetinterface module 1308 as described in FIG. 8, block 810. Filesystemmount request module 1312 transmits a filesystem mount request to theportable storage device as described in FIG. 8, block 812. Receivefilesystem mount module 1314 receives notification that the requestedfilesystem was mounted as described in FIG. 8, block 814. Displaymounted filesystem module 1316 displays the shared filesystem asdescribed in FIG. 8, block 816. Signal failure module 1318 signals afailure as described in FIG. 8, block 818.

FIG. 14A is a block diagram of network file server 1400 that handlesaccesses to the shared filesystem on the portable storage device. In oneembodiment, network file server 1400 is the network file server that ispart of the portable storage service as described in FIGS. 3-5 above.Network file server comprises filesystem request receiving module 1402and filesystem fulfillment module 1404. Filesystem request receivingmodule 1402 receives filesystem requests as described in FIG. 9, block902. Filesystem fulfillment module 1404 fulfills those requests asdescribed in FIG. 9, block 904.

FIG. 14B is a block diagram of host application 1450 that makes accessesrequests to the shared filesystem on the portable storage device. In oneembodiment, host application is a file browsing application or otherhost application as described in FIGS. 3-5 above. Host application 1450includes filesystem request transmission module 1452 and filesystemrequest notification module 1454. Filesystem request transmission module1452 transmits a request to access the shared filesystem of the portablestorage device as described in FIG. 10, block 1002. Filesystem requestnotification module 1454 a receives a notification of a result to thefilesystem access request as described in FIG. 10, block 1002.

FIG. 15 shows one example of a data processing system 1500, which may beused with one embodiment of the present invention. For example, thesystem 1500 may be implemented including a host as shown in FIG. 1. Notethat while FIG. 15 illustrates various components of a computer system,it is not intended to represent any particular architecture or manner ofinterconnecting the components as such details are not germane to thepresent invention. It will also be appreciated that network computersand other data processing systems or other consumer electronic deviceswhich have fewer components or perhaps more components may also be usedwith the present invention.

As shown in FIG. 15, the computer system 1500, which is a form of a dataprocessing system, includes a bus 1503 which is coupled to amicroprocessor(s) 1505 and a ROM (Read Only Memory) 1507 and volatileRAM 1509 and a non-volatile memory 1511. The microprocessor 1505 mayretrieve the instructions from the memories 1507, 1509, 1511 and executethe instructions to perform operations described above. The bus 1503interconnects these various components together and also interconnectsthese components 1505, 1507, 1509, and 1511 to a display controller anddisplay device 1513 and to peripheral devices such as input/output (I/O)devices which may be mice, keyboards, modems, network interfaces,printers and other devices which are well known in the art. Typically,the input/output devices 1515 are coupled to the system throughinput/output controllers 1517. The volatile RAM (Random Access Memory)1509 is typically implemented as dynamic RAM (DRAM) which requires powercontinually in order to refresh or maintain the data in the memory.

The mass storage 1511 is typically a magnetic hard drive or a magneticoptical drive or an optical drive or a DVD RAM or a flash memory orother types of memory systems which maintain data (e.g. large amounts ofdata) even after power is removed from the system. Typically, the massstorage 1511 will also be a random access memory although this is notrequired. While FIG. 15 shows that the mass storage 1511 is a localdevice coupled directly to the rest of the components in the dataprocessing system, it will be appreciated that the present invention mayutilize a non-volatile memory which is remote from the system, such as anetwork storage device which is coupled to the data processing systemthrough a network interface such as a modem, an Ethernet interface or awireless network. The bus 1503 may include one or more buses connectedto each other through various bridges, controllers and/or adapters as iswell known in the art.

FIG. 16 shows an example of another data processing system 1600 whichmay be used with one embodiment of the present invention. For example,system 1600 may be implemented as a portable storage device as shown inFIG. 1. The data processing system 1600 shown in FIG. 16 includes aprocessing system 1611, which may be one or more microprocessors, orwhich may be a system on a chip integrated circuit, and the system alsoincludes memory 1601 for storing data and programs for execution by theprocessing system. The system 1600 also includes an audio input/outputsubsystem 1605 which may include a microphone and a speaker for, forexample, playing back music or providing telephone functionality throughthe speaker and microphone.

A display controller and display device 1607 provide a visual userinterface for the user; this digital interface may include a graphicaluser interface which is similar to that shown on a Macintosh computerwhen running OS X operating system software. The system 1600 alsoincludes one or more wireless transceivers 1603 to communicate withanother data processing system, such as the system 1600 of FIG. 16. Awireless transceiver may be a WLAN transceiver, an infrared transceiver,a Bluetooth transceiver, and/or a wireless cellular telephonytransceiver. It will be appreciated that additional components, notshown, may also be part of the system 1600 in certain embodiments, andin certain embodiments fewer components than shown in FIG. 16 may alsobe used in a data processing system. The system 1600 further includesone or more communications ports 1617 to communicate with another dataprocessing system, such as the system 1500 of FIG. 15. Thecommunications port may be a USB port, Firewire port, Bluetoothinterface, etc.

The data processing system 1600 also includes one or more input devices1613 which are provided to allow a user to provide input to the system.These input devices may be a keypad or a keyboard or a touch panel or amulti touch panel. The data processing system 1600 also includes anoptional input/output device 1615 which may be a connector for a dock.It will be appreciated that one or more buses, not shown, may be used tointerconnect the various components as is well known in the art. Thedata processing system shown in FIG. 16 may be a handheld computer or apersonal digital assistant (PDA), or a cellular telephone with PDA likefunctionality, or a handheld computer which includes a cellulartelephone, or a media player, such as an iPod, or devices which combineaspects or functions of these devices, such as a media player combinedwith a PDA and a cellular telephone in one device or an embedded deviceor other consumer electronic devices. In other embodiments, the dataprocessing system 1600 may be a network computer or an embeddedprocessing device within another device, or other types of dataprocessing systems which have fewer components or perhaps morecomponents than that shown in FIG. 16.

At least certain embodiments of the inventions may be part of a digitalmedia player, such as a portable music and/or video media player, whichmay include a media processing system to present the media, a storagedevice to store the media and may further include a radio frequency (RF)transceiver (e.g., an RF transceiver for a cellular telephone) coupledwith an antenna system and the media processing system. In certainembodiments, media stored on a remote storage device may be transmittedto the media player through the RF transceiver. The media may be, forexample, one or more of music or other audio, still pictures, or motionpictures.

The portable media player may include a media selection device, such asa click wheel input device on an iPod® or iPod Nano® media player fromApple, Inc. of Cupertino, Calif., a touch screen input device,pushbutton device, movable pointing input device or other input device.The media selection device may be used to select the media stored on thestorage device and/or the remote storage device. The portable mediaplayer may, in at least certain embodiments, include a display devicewhich is coupled to the media processing system to display titles orother indicators of media being selected through the input device andbeing presented, either through a speaker or earphone(s), or on thedisplay device, or on both display device and a speaker or earphone(s).Examples of a portable media player are described in published U.S. Pat.No. 7,345,671 and U.S. published patent number 2004/0224638, both ofwhich are incorporated herein by reference.

Portions of what was described above may be implemented with logiccircuitry such as a dedicated logic circuit or with a microcontroller orother form of processing core that executes program code instructions.Thus processes taught by the discussion above may be performed withprogram code such as machine-executable instructions that cause amachine that executes these instructions to perform certain functions.In this context, a “machine” may be a machine that converts intermediateform (or “abstract”) instructions into processor specific instructions(e.g., an abstract execution environment such as a “virtual machine”(e.g., a Java Virtual Machine), an interpreter, a Common LanguageRuntime, a high-level language virtual machine, etc.), and/or,electronic circuitry disposed on a semiconductor chip (e.g., “logiccircuitry” implemented with transistors) designed to executeinstructions such as a general-purpose processor and/or aspecial-purpose processor. Processes taught by the discussion above mayalso be performed by (in the alternative to a machine or in combinationwith a machine) electronic circuitry designed to perform the processes(or a portion thereof) without the execution of program code.

The present invention also relates to an apparatus for performing theoperations described herein. This apparatus may be specially constructedfor the required purpose, or it may comprise a general-purpose computerselectively activated or reconfigured by a computer program stored inthe computer. Such a computer program may be stored in a computerreadable storage medium, such as, but is not limited to, any type ofdisk including floppy disks, optical disks, CD-ROMs, andmagnetic-optical disks, read-only memories (ROMs), RAMs, EPROMs,EEPROMs, magnetic or optical cards, or any type of media suitable forstoring electronic instructions, and each coupled to a computer systembus.

A machine readable medium includes any mechanism for storing ortransmitting information in a form readable by a machine (e.g., acomputer). For example, a machine readable medium includes read onlymemory (“ROM”); random access memory (“RAM”); magnetic disk storagemedia; optical storage media; flash memory devices; etc.

An article of manufacture may be used to store program code. An articleof manufacture that stores program code may be embodied as, but is notlimited to, one or more memories (e.g., one or more flash memories,random access memories (static, dynamic or other)), optical disks,CD-ROMs, DVD ROMs, EPROMs, EEPROMs, magnetic or optical cards or othertype of machine-readable media suitable for storing electronicinstructions. Program code may also be downloaded from a remote computer(e.g., a server) to a requesting computer (e.g., a client) by way ofdata signals embodied in a propagation medium (e.g., via a communicationlink (e.g., a network connection)).

The preceding detailed descriptions are presented in terms of algorithmsand symbolic representations of operations on data bits within acomputer memory. These algorithmic descriptions and representations arethe tools used by those skilled in the data processing arts to mosteffectively convey the substance of their work to others skilled in theart. An algorithm is here, and generally, conceived to be aself-consistent sequence of operations leading to a desired result. Theoperations are those requiring physical manipulations of physicalquantities. Usually, though not necessarily, these quantities take theform of electrical or magnetic signals capable of being stored,transferred, combined, compared, and otherwise manipulated. It hasproven convenient at times, principally for reasons of common usage, torefer to these signals as bits, values, elements, symbols, characters,terms, numbers, or the like.

It should be kept in mind, however, that all of these and similar termsare to be associated with the appropriate physical quantities and aremerely convenient labels applied to these quantities. Unlessspecifically stated otherwise as apparent from the above discussion, itis appreciated that throughout the description, discussions utilizingterms such as “configuring,” “communicating,” “advertising,” “sharing,”“detecting,” “associating,” “initiating,” “assigning,” “receiving,”“retrieving,” “enabling,” “adding,” ‘coupling,” “fulfilling,”“transmitting,” or the like, refer to the action and processes of acomputer system, or similar electronic computing device, thatmanipulates and transforms data represented as physical (electronic)quantities within the computer system's registers and memories intoother data similarly represented as physical quantities within thecomputer system memories or registers or other such information storage,transmission or display devices.

The processes and displays presented herein are not inherently relatedto any particular computer or other apparatus. Various general-purposesystems may be used with programs in accordance with the teachingsherein, or it may prove convenient to construct a more specializedapparatus to perform the operations described. The required structurefor a variety of these systems will be evident from the descriptionbelow. In addition, the present invention is not described withreference to any particular programming language. It will be appreciatedthat a variety of programming languages may be used to implement theteachings of the invention as described herein.

The foregoing discussion merely describes some exemplary embodiments ofthe present invention. One skilled in the art will readily recognizefrom such discussion, the accompanying drawings and the claims thatvarious modifications can be made without departing from the spirit andscope of the invention.

What is claimed is:
 1. A computerized method, comprising: at afileserver implemented on a portable storage device: receiving, from ahost computer that is communicatively coupled to the portable storagedevice, a request to construct within the portable storage device ashared filesystem; retrieving a list of a plurality of applicationsresident on the portable storage device, wherein each application of theplurality of applications has a corresponding private filesystem, andeach private filesystem is in a security sandbox that preventsnon-corresponding applications from accessing the private filesystem;constructing the shared filesystem within the portable storage device bycarrying out steps that include: determining, for each application ofthe plurality of applications, whether the application is configured toshare with the host computer a specific category of data that isincluded in the private file system, and for each application that isconfigured to share with the host computer the specific category ofdata: adding, to the shared filesystem, a link to the correspondingprivate filesystem, wherein the link enables the host computer to accessthe specific category of data, but not other categories of data, via theshared filesystem; and advertising the shared filesystem of the portablestorage device to the host computer.
 2. The computerized method of claim1, wherein the shared filesystem appears as a shared volume to the hostcomputer.
 3. The computerized method of claim 1, wherein advertisingcomprises transmitting an advertisement that includes an identifier ofthe portable storage device to the host computer.
 4. The computerizedmethod of claim 3, wherein the identifier is a serial number of theportable storage device.
 5. The computerized method of claim 1, whereinan application resident on the host computer has access to files in theshared filesystem.
 6. The computerized method of claim 1, furthercomprising: coupling the portable storage device to the host computerwith a universal serial bus link.
 7. The computerized method of claim 1,further comprising: assigning a private internet protocol (IP) addressto an interface, wherein the shared filesystem is bound to theinterface.
 8. The computerized method of claim 7, wherein the sharedfilesystem is accessible via the interface with the private IP address.9. A non-transitory machine-readable medium configured to storeinstructions that, when executed by a processor included in portablestorage device, cause the portable storage device to carry out stepsthat include: receiving, from a host computer that is communicativelycoupled to the portable storage device, a request to construct withinthe portable storage device a shared filesystem; retrieving a list of aplurality of applications resident on the portable storage device,wherein each application of the plurality of applications has acorresponding private filesystem, and each private filesystem is in asecurity sandbox that prevents non-corresponding applications fromaccessing the private filesystem; constructing the shared filesystemwithin the portable storage device by carrying out steps that include:determining, for each application of the plurality of applications,whether the application is configured to share with the host computer aspecific category of data that is included in the private file system,and for each application that is configured to share with the hostcomputer the specific category of data: adding, to the sharedfilesystem, a link to the corresponding private filesystem, wherein thelink enables the host computer to access the specific category of data,but not other categories of data, via the shared filesystem; andadvertising the shared filesystem of the portable storage device to thehost computer.
 10. The non-transitory machine-readable medium of claim9, wherein the shared filesystem appears as a shared volume to the hostcomputer.
 11. The non-transitory machine-readable medium of claim 9,wherein advertising comprises transmitting an advertisement thatincludes an identifier of the portable storage device to the hostcomputer.
 12. The non-transitory machine-readable medium of claim 9,wherein the steps further include: coupling the portable storage deviceto the host computer with a universal serial bus link.
 13. Thenon-transitory machine-readable medium of claim 9, wherein the stepsfurther include: assigning a private internet protocol (IP) address toan interface, wherein the shared filesystem is bound to the interface.14. The non-transitory machine-readable medium of claim 11, wherein theidentifier is a serial number of the portable storage device.
 15. Thenon-transitory machine-readable medium of claim 9, wherein anapplication resident on the host computer has access to files in theshared filesystem.
 16. The non-transitory machine-readable medium ofclaim 13, wherein the shared filesystem is accessible via the interfacewith the private IP address.
 17. A portable storage device, comprising:a processor configured to carry out steps that include: receiving, froma host computer that is communicatively coupled to the portable storagedevice, a request to construct within the portable storage device ashared filesystem; retrieving a list of a plurality of applicationsresident on the portable storage device, wherein each application of theplurality of applications has a corresponding private filesystem, andeach private filesystem is in a security sandbox that preventsnon-corresponding applications from accessing the private filesystem;constructing the shared filesystem within the portable storage device bycarrying out steps that include: determining, for each application ofthe plurality of applications, whether the application is configured toshare with the host computer a specific category of data that isincluded in the private file system, and for each application that isconfigured to share with the host computer the specific category ofdata: adding, to the shared filesystem, a link to the correspondingprivate filesystem, wherein the link enables the host computer to accessthe specific category of data, but not other categories of data, via theshared filesystem; and advertising the shared filesystem of the portablestorage device to the host computer.
 18. The portable storage device ofclaim 17, wherein the shared filesystem appears as a shared volume tothe host computer.
 19. The portable storage device of claim 17, whereinadvertising comprises transmitting an advertisement that includes anidentifier of the portable storage device to the host computer.
 20. Theportable storage device of claim 19, wherein the identifier is a serialnumber of the portable storage device.
 21. The portable storage deviceof claim 17, wherein an application resident on the host computer hasaccess to files in the shared filesystem.
 22. The portable storagedevice of claim 17, wherein the steps further include: coupling theportable storage device to the host computer with a universal serial buslink.
 23. The portable storage device of claim 17, wherein the stepsfurther include: assigning a private internet protocol (IP) address toan interface, wherein the shared filesystem is bound to the interface.24. The portable storage device of claim 23, wherein the sharedfilesystem is accessible via the interface with the private IP address.